package server.business.service.Impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import server.business.mapper.AllBusinessMapper;
import server.business.pojo.Allbusiness;
import server.business.service.AllbusinessService;

@Service
public class AllbusinessServiceImpl extends ServiceImpl<AllBusinessMapper, Allbusiness> implements AllbusinessService {

    @Autowired
    AllBusinessMapper allbusinessMap;
    @Override
    public Allbusiness getcurrentbusiness(Integer id) {

        Allbusiness allbusiness = getById(id);

        return allbusiness;
    }

    @Override
    public IPage<Allbusiness> getWhoCanCreate(Page<Allbusiness> page, String doctorid) {
        return allbusinessMap.getWhoCanCreate(page,doctorid);
    }
}
